

// 产品管理


// const GoodsManage=()=>import('@/views/GoodsManage/index.vue');
const GoodsManage = (resolve) => require(['@/views/GoodsManage'], resolve)
// const GoodsList=()=>import('@/views/GoodsManage/List/index.vue');
const GoodsList = (resolve) => require(['@/views/GoodsManage/List'], resolve)
// import AddGoodItem from '@/views/GoodsManage/List/AddGoodItem'
const AddGoodItem = (resolve) => require(['@/views/GoodsManage/List/AddGoodItem'], resolve)
// import GoodsCategory from '@/views/GoodsManage/Category'
const GoodsCategory = (resolve) => require(['@/views/GoodsManage/Category'], resolve)

// // 订单管理
// import OrderManage from '@/views/OrderManage'
const OrderManage = (resolve) => require(['@/views/OrderManage'],resolve)
const OrderList = (resolve) => require(['@/views/OrderManage/List'],resolve)
const OrderCollect = (resolve) => require(['@/views/OrderManage/Collect'],resolve)
// const OrderCollect = eval('()=>import("@/views/OrderManage/Collect")')
const OrderAudit = (resolve) => require(['@/views/OrderManage/Audit'],resolve)
// import OrderList from '@/views/OrderManage/List'
// import OrderCollect from '@/views/OrderManage/Collect'
// import OrderAudit from '@/views/OrderManage/Audit'

// // 广告管理
// import AdvertManage from '@/views/AdvertManage'
// import AdvertList from '@/views/AdvertManage/List'
// import AdvertCategory from '@/views/AdvertManage/Category'

const AdvertManage = (resolve) => require(['@/views/AdvertManage'], resolve)
const AdvertList = (resolve) => require(['@/views/AdvertManage/List'], resolve)
const AdvertCategory = (resolve) => require(['@/views/AdvertManage/Category'], resolve)


// // 系统管理
// import RoloManage from '@/views/System/RoloManage'
// import UserManage from '@/views/System/UserManage'
// import System from '@/views/System'
const System = (resolve) => require(['@/views/System'], resolve)
const RoloManage = (resolve) => require(['@/views/System/RoloManage'], resolve)
const UserManage = (resolve) => require(['@/views/System/UserManage'], resolve)


export const menu=[
    
    {
        path: '/goods',
        name: 'goods',
        component: GoodsManage,
        redirect: '/goods/goodlist',
        meta: {
            title: '产品管理'
        },
        children: [
            {
                path: 'goodlist',
                name: 'goodlist',
                component: GoodsList,
                meta: {
                    title: '产品列表'
                },
            },
            {
                path: 'addgooditem',
                name: 'addgooditem',
                component: AddGoodItem,
                meta: {
                    activepath: '/goods/goodlist',
                    title: '添加产品'
                }
            }
            ,
            {
                path: 'goodcategory',
                name: 'goodcategory',
                component: GoodsCategory,
                meta: {
                    title: '产品分类'
                },
            },

        ]
    },
    {
        path: '/order',
        name: 'order',
        component: OrderManage,
        redirect: '/order/orderlist',
        meta: {
            title: '订单管理'
        },
        children: [
            {
                path: 'orderlist',
                name: 'orderlist',
                component: OrderList,
                meta: {
                    title: '订单列表'
                },
            },
            {
                path: 'ordercollect',
                name: 'ordercollect',
                component: OrderCollect,
                meta: {
                    title: '汇总订单'
                },
            },
            {
                path: 'orderaudit',
                name: 'orderaudit',
                component: OrderAudit,
                meta: {
                    title: '订单审核'
                },
            }
        ]
    },
    {
        path: '/advert',
        name: 'advert',
        component: AdvertManage,
        redirect: '/advert/advertlist',
        meta: {
            title: '广告管理'
        },
        children: [
            {
                path: 'advertlist',
                name: 'advertlist',
                component: AdvertList,
                meta: {
                    title: '广告列表'
                },
            },
            {
                path: 'advertcategory',
                name: 'advertcategory',
                component: AdvertCategory,
                meta: {
                    title: '广告分类'
                },
            }
        ]
    },
    {
        path:'/system',
        name:'system',
        component:System,
        redirect:'/system/rolomanage',
        meta: {
            title: '系统管理'
        },
        children:[
            {
                path:'rolemanage',
                name:'rolemanage',
                component:RoloManage,
                meta:{
                    title:'角色管理'
                }
            },
            {
                path:'usermanage',
                name:'usermanage',
                component:UserManage,
                meta: {
                    title: '用户管理'
                }
            }
        ]

    }


]